//
// Created by 17775 on 2024/10/17.
//

#include "Single_PowerProfileUI.h"

Single_PowerProfileUI::Single_PowerProfileUI(QWidget *parent) : PowerProfileBase(parent) {
    setTitleName("Single Measurement: Cross Section");
}

void Single_PowerProfileUI::processData(std::shared_ptr<PowerProfileData<std::vector<float>>> &data) {
    getCustomPlot()->graph(0)->setData(convertVectorToQList(data->diameterData()),convertVectorToQList(data->powerData()));
    refreshCursorRange();
    refreshViewRange();
    refreshView();
}